package service

import (
	"os"

	winservice "github.com/kardianos/service"
)

type Program struct {
	Run func()
}

func (p *Program) Start(s winservice.Service) error {
	go p.run()
	return nil
}
func (p *Program) run() {
	p.Run()
}
func (p *Program) Stop(s winservice.Service) error {
	os.Exit(0)
	return nil
}
